﻿#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <math.h>

typedef double Real;

typedef struct {
	int m;
	int n;
	int data[20][20];
}Matrix;
 
typedef struct 
{
	int n;
}Context;

Context context;
 
Matrix* read_mat(Matrix* A)
{
	scanf("%d %d", &A->m, &A->n);
	for (int i = 0; i < A->m; ++i)
		for (int j = 0; j < A->n; ++j)
			scanf("%d", &A->data[i][j]);
	return A;
}

void read_data(Context* ctx)
{
	scanf("%d", &ctx->n);
}

void do_task(Context* ctx)
{
	char buf[255];
	char min[255];
	int lmin = 255;
	for (int i = 0; i < ctx->n; ++i)
	{
		scanf("%s", buf);
		if (i == 0 || strcmp(min,buf)>0)
			strcpy(min, buf);
	}
	printf("Min is: %s\n", min);
}

void solve(Context* ctx)
{
	read_data(ctx);
	do_task(ctx);
}

int main()
{
	freopen("D:/Develop/GitRepos/MOOC/浙江大学/数据结构/201906/DataStructure/M2019秋C入门和进阶练习集/7-156.txt", "r", stdin);
	solve(&context);
	return 0;
}
